package nju.software.xkxt.web.controller;

import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;

import org.springframework.stereotype.Controller;
import org.springframework.ui.ModelMap;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;

@Controller
public class Test {
	@RequestMapping(value = "/show1.do", method = RequestMethod.GET)
	public String show(HttpServletRequest request,
			HttpServletResponse response, ModelMap map){
		return "1";
	}
	@RequestMapping(value = "/show2.do", method = RequestMethod.POST)
	public String ret(HttpServletRequest request,
			HttpServletResponse response, ModelMap map){
		String source=request.getParameter("source");
		map.addAttribute("source",source);
		return "2";
	}

}
